package com.booksystem.campuslibrarymanagementsystem.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.booksystem.campuslibrarymanagementsystem.commen.request.userquest.BookBorrowrequst.Approval;
import com.booksystem.campuslibrarymanagementsystem.commen.request.userquest.Renewalapprovalrequest.Renewalapproval;
import com.booksystem.campuslibrarymanagementsystem.commen.result.userresuilt.RenewalTable;
import com.booksystem.campuslibrarymanagementsystem.entity.RenewalapprovalTable;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDate;
import java.util.List;

public interface RenewalapprovalTableService extends IService<RenewalapprovalTable> {
    int add(RenewalapprovalTable hh);

    List<RenewalTable> liststatus(String account, String approvalstate);
    List<RenewalapprovalTable>  existsByAccountAndBookidi(String account, int bookid);
    List<RenewalTable> selectByaccount(@Param("account") String account);
    int deleteByAccountAndBookid(@Param("account") String account, @Param("approvalid") int approvalid);
    List<RenewalapprovalTable> queryByAccount(String account);
    List<RenewalapprovalTable> querydislist(String approvalstate);
    void unapproval(@Param("account") String account, @Param("approvalTime") LocalDate approvalTime ,
                    @Param("bookid") String bookid,
                    @Param("Approvalstate")String Approvalstate);
    void onapproval(@Param("account") String account, @Param("approvalTime") LocalDate approvalTime ,
                    @Param("bookid") String bookid,
                    @Param("Approvalstate")String Approvalstate);
}
